
<?php

$securities_param = get_param_value('securities_param', 'xray_securities_param', '');
if (!$securities_param) {
	$securities_param = $vars['sec'];
}
$_SESSION['xray_securities_param'] = $securities_param;
//print_r($securities_param);

$fund_param = get_param_value('fund_param', 'xray_fund_param', '');
$_SESSION['xray_fund_param'] = $fund_param;
?>

<div class="elgg-module  elgg-module-aside">
	<div class="elgg-head"><h3>Security</h3></div>
	<div class="elgg-body">
<?php
$action_url = elgg_get_site_url()."xray/redirect";
echo "<form method='get' action='$action_url'>";
echo elgg_view('input/autocomplete_securities', array(
	'name' => 'securities_param',
	'value' => $securities_param,
	'width' => 'auto',
));

echo '</p><p><label>Fund</label><br/>'; 
echo elgg_view('input/dropdown', array(
	'name' => 'fund_param',
	'value' => $fund_param,
	'options_values' => get_fund_array(),
));

echo '<br/><br/>';
echo elgg_view('input/submit', array(
		'name' => 'search',
		'value' => 'Display',
));
echo "</form><br/>";
?>
	</div>
</div>

<?php

echo elgg_view('focus/my', $vars);

echo elgg_view('focus/all', $vars);

?>